//
//  COCOAFANPmsgWindowController.h
//  CocoaFan
//
//  Created by Chen Xianan on 2009-03-29.
//  Copyright 2009 realazy.org. All rights reserved.
//

#import <Cocoa/Cocoa.h>

extern NSString * const COCOAFANSendPmsgNotification;

typedef enum {
	COCOAFAN_PMSGTIP_NORMAL,
	COCOAFAN_PMSGTIP_WARNING
} COCOAFAN_PMSGTIP_TYPE;

@class YRKSpinningProgressIndicator;
@interface COCOAFANPmsgWindowController : NSWindowController {
	NSTextField *msgField;
	NSTextField *counter;
	IBOutlet NSTextField *tipField;
	IBOutlet YRKSpinningProgressIndicator *indicator;
	NSDictionary *statusContent;
	NSTimer *timer;
	NSString *tip;
	NSColor *textColor;
	BOOL needsShowIndicator;
}

@property (retain) NSDictionary *statusContent;
@property (retain, readonly) IBOutlet NSTextField *msgField;
@property (retain, readonly) IBOutlet NSTextField *counter;
@property (copy) NSString *tip;
@property (copy) NSColor *textColor;
@property (assign) BOOL needsShowIndicator;

- (void)_showTip:(NSString *)tip showIndicator:(BOOL)show type:(COCOAFAN_PMSGTIP_TYPE)type;
- (void)showTip:(NSString *)tip type:(COCOAFAN_PMSGTIP_TYPE)type;
- (void)showTipWithIndicator:(NSString *)tip type:(COCOAFAN_PMSGTIP_TYPE)type;
- (void)scheduledCloseWindow:(NSTimeInterval)interval;
- (IBAction)sendMessage:(id)sender;
- (IBAction)closeWindow:(id)sender;
@end
